package com.ZengQi.event.controller;

import com.ZengQi.event.entity.Comment;
import com.ZengQi.event.service.CommentService;
import com.ZengQi.event.service.impl.CommentServiceImpl;

/**
 * 添加评论界面的controller，我对controller的理解就是调用service层实现类的方法获取到view层想要的数据并进行一定的处理然后返回给view层
 * 同样的也可以接收view层数据然后再调用service层方法对数据库进行更新
 */
public class AddCommentViewController {
    private CommentService commentService=new CommentServiceImpl();

   public boolean addSuccess(Comment comment){
        return commentService.saveComment(comment);
    }

}
